from scipy import ndimage
import numpy
#
# masses = numpy.array([
# [0,  0,  0,  0],
# [0,  1,  0,  0],
# [0,  2,  0,  0],
# [1,  0,  0,  0],
# [1,  1,  0,  0],
# [1,  2,  0,  0],
# [2,  0,  0,  0],
# [2,  1,  0,  0],
# [2,  2,  0,  0]])
# print(ndimage.measurements.center_of_mass(masses))


def read_txt():
    path="db.txt"
    with open(path, 'r') as f:
        list=f.readlines()
    max=list[0]
    number_list=list[1].split(",")
    print(list,int(max),number_list)
    for i in number_list:
        print(float(i))

if __name__ == '__main__':
    read_txt()
    print("success")